<!DOCTYPE html>
<html lang="zh-CN">
<head>
<title>登陆页面</title>
<#include "include_page/header.html"/>
<script type="text/javascript">
$(function(){$('input').eq(0).focus();});
</script>
</head>
<body>
	<main>
	    <div>
    	<#if user??>
    		<p class="message">您已经登录了</p>
    		<script>${(returnUrl?has_content)?then("window.location.href='${(returnUrl?html)!}'","")}</script>
    	<#else>
			<form action="login.do" method="post" class="center login-form">
				<p><input type="text" name="username" class="input-text" placeholder="用户名" title="用户名"/></p>
				<p><input type="password" name="password" class="input-text" placeholder="密码" title="密码"/></p>
				<p class="text-center">
					<input type="submit" class="button" value="登  录"/>
					<input type="hidden" name="returnUrl" value="${returnUrl!''?html}"/>
				</p>
				<#if error??>
					<p class="message red"><@t.m error/></p>
				</#if>
				<#if message??>
					<p class="message"><@t.m "message."+message/></p>
				</#if>
			</form>
		</#if>
	    </div>
	</main>
</body>
</html>